package yaty.lee.tencent.weibo.modules.oauth2.ig.vo;

import yaty.lee.tencent.weibo.domain.VO;
import yaty.lee.tencent.weibo.util.OAuthPropertiesUtil;

public class ImplicitAuthVO extends VO {
    private final String client_id = OAuthPropertiesUtil.getKey();
    private final String redirect_uri = OAuthPropertiesUtil.getAuthorizeRedirectUri();
    private final String response_type = "token";
    private boolean wap;
    private String state;
    private boolean forcelogin = true;

    public ImplicitAuthVO() {
        super();
    }

    public boolean isWap() {
        return wap;
    }

    public void setWap(boolean wap) {
        this.wap = wap;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public boolean isForcelogin() {
        return forcelogin;
    }

    public void setForcelogin(boolean forcelogin) {
        this.forcelogin = forcelogin;
    }

    public String getClient_id() {
        return client_id;
    }

    public String getRedirect_uri() {
        return redirect_uri;
    }

    public String getResponse_type() {
        return response_type;
    }

    @Override
    public String getReqUrl() {
        return "https://open.t.qq.com/cgi-bin/oauth2/authorize";
    }

    public class Back {
        private String access_token;
        private long expires_in;
        private String openid;
        private String openkey;
        private String refresh_token;
        private String state;
        private String name;
        private String nick;

        public Back() {
            super();
        }

        public String getAccess_token() {
            return access_token;
        }

        public void setAccess_token(String access_token) {
            this.access_token = access_token;
        }

        public long getExpires_in() {
            return expires_in;
        }

        public void setExpires_in(long expires_in) {
            this.expires_in = expires_in;
        }

        public String getOpenid() {
            return openid;
        }

        public void setOpenid(String openid) {
            this.openid = openid;
        }

        public String getOpenkey() {
            return openkey;
        }

        public void setOpenkey(String openkey) {
            this.openkey = openkey;
        }

        public String getRefresh_token() {
            return refresh_token;
        }

        public void setRefresh_token(String refresh_token) {
            this.refresh_token = refresh_token;
        }

        public String getState() {
            return state;
        }

        public void setState(String state) {
            this.state = state;
        }

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public String getNick() {
            return nick;
        }

        public void setNick(String nick) {
            this.nick = nick;
        }

    }

}
